package exam.business.service;

import exam.common.constant.ResultPort;
import exam.common.key.KeyExamination;
import exam.common.util.ConvertUtils;
import exam.model.dao.TExaminationDAO;
import exam.system.business.AbstractService;
import exam.system.business.BusinessServiceInfo;
/**
 * <p>ExaminationDeleteService</p>
 * <br>
 * <p>Yeu cau xu ly xoa de thi</p>
 * 
 * @author Phong
 * @version (create: 20/5/2012) (update: 21/5/2012)
 */
public class ExaminationDeleteService extends AbstractService {
	// tExaminationDAO
	private TExaminationDAO tExaminationDAO = new TExaminationDAO();
	@Override
	public String executeService(BusinessServiceInfo serviceInfo)
			throws Exception {
		// Lay examId tu serviceInfo
		String examId = serviceInfo.getString(KeyExamination.EXAM_ID);
		// Goi phuong thuc xoa de thi
		tExaminationDAO.deleteExamination(ConvertUtils.convertStringToLong(examId));
		return ResultPort.SUCCESS;
	}

}
